package com.example.service.impl;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.example.entity.Diring;
import com.example.mapper.diringMapper;
import com.example.service.diringService;
import com.example.util.page1;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
import java.util.Map;

@Service
public class diringServiceImpl implements diringService {

    @Autowired
    private diringMapper diringMapper;

    @Override
    public Page<Map> findpage(page1 page1) {
        Page p1 = new Page(page1.getPageNo(), page1.getPageSize());
        return diringMapper.findDriver(p1, page1);
    }

    @Override
    public Diring findById(Integer id) {
        return diringMapper.selectByid(id);
    }


}
